Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[TensorRT EP] Refactor OrtTensorRTProviderOptions initialization and make it easy to add new field #17617

Merged
merged 26 commits into from
Oct 6, 2023

Conversation

chilo-ms
Copy link
Contributor

@chilo-ms chilo-ms commented Sep 19, 2023

Two major modifications of this PR:

  1. Refactor OrtTensorRTProviderOptions initialization and make it easy to add new field.
  2. Make Python API capable of using TensorRT plugins by adding new Python binding api register_tensorrt_plugins_as_custom_ops. (It needs to register ep's custom op domain before model load. For C++ API, it's slightly different, when calling SessionOptionsAppendExecutionProvider_TensorRT_XX, it appends cutom op domain to session option. Later ORT can register custom op domain from session option before model loading)

@chilo-ms chilo-ms marked this pull request as ready for review September 22, 2023 00:21
@chilo-ms chilo-ms requested a review from a team as a code owner September 22, 2023 00:21
@chilo-ms chilo-ms requested a review from jywu-msft September 22, 2023 00:22
@jywu-msft
Copy link
Member

i kicked off python packaging pipeline to test this PR

@jywu-msft
Copy link
Member

fix python lint checks

jywu-msft
jywu-msft previously approved these changes Sep 29, 2023
@chilo-ms
Copy link
Contributor Author

chilo-ms commented Oct 2, 2023 via email

@chilo-ms chilo-ms merged commit 569876f into main Oct 6, 2023
@chilo-ms chilo-ms deleted the chi/trt_plugin_python branch October 6, 2023 21:12
yf711 added a commit that referenced this pull request Oct 9, 2023
…ion and make it easy to add new field (#17617)"

This reverts commit 569876f.
yf711 added a commit that referenced this pull request Oct 11, 2023
…ion and make it easy to add new field (#17617)"

This reverts commit 569876f.
chilo-ms added a commit that referenced this pull request Oct 16, 2023
We removed tensorrt_provider_factory.h in the
[PR](#17617).
Need to remove the copy of this file when cmake install.
jchen351 pushed a commit that referenced this pull request Oct 18, 2023
We removed tensorrt_provider_factory.h in the
[PR](#17617).
Need to remove the copy of this file when cmake install.
kleiti pushed a commit to kleiti/onnxruntime that referenced this pull request Mar 22, 2024
…make it easy to add new field (microsoft#17617)

Two major modifications of this PR:

1. Refactor OrtTensorRTProviderOptions initialization and make it easy
to add new field.
2. Make Python API capable of using TensorRT plugins by adding new
Python binding api `register_tensorrt_plugins_as_custom_ops`. (It needs
to register ep's custom op domain before model load. For C++ API, it's
slightly different, when calling
SessionOptionsAppendExecutionProvider_TensorRT_XX, it appends cutom op
domain to session option. Later ORT can register custom op domain from
session option before model loading)
kleiti pushed a commit to kleiti/onnxruntime that referenced this pull request Mar 22, 2024
We removed tensorrt_provider_factory.h in the
[PR](microsoft#17617).
Need to remove the copy of this file when cmake install.
siweic0 pushed a commit to siweic0/onnxruntime-web that referenced this pull request May 9, 2024
…make it easy to add new field (microsoft#17617)

Two major modifications of this PR:

1. Refactor OrtTensorRTProviderOptions initialization and make it easy
to add new field.
2. Make Python API capable of using TensorRT plugins by adding new
Python binding api `register_tensorrt_plugins_as_custom_ops`. (It needs
to register ep's custom op domain before model load. For C++ API, it's
slightly different, when calling
SessionOptionsAppendExecutionProvider_TensorRT_XX, it appends cutom op
domain to session option. Later ORT can register custom op domain from
session option before model loading)
@gcunhase
Copy link

Is register_tensorrt_plugins_as_custom_ops also available in the Python API? @chilo-ms @jywu-msft

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants